using UnityEngine;

public class GameMoveControl : MonoBehaviour
{
    public float MoveSpeed { get; set; } = 100;
    public Vector3 MoveDirection { get; set; }

    public bool CanMove = false;

    private void Update()
    {
        if (CanMove)
        {
            float horizontalInput = 0f;
            float verticalInput = 0f;

            horizontalInput = Input.GetAxisRaw("Horizontal");
            verticalInput = Input.GetAxisRaw("Vertical");

            MoveDirection=new Vector3(horizontalInput, 0, verticalInput).normalized;
            
            transform.Translate(MoveDirection*MoveSpeed*Time.deltaTime);
        }
        
    }

}
